rem eg.命令：上传文件夹：C:\Users\admin\Desktop\tosutile\tos_upload.bat C:\Users\admin\Desktop\tosutile\test SecondTest/Test true
rem eg.命令：上传文件：C:\Users\admin\Desktop\tosutile\tos_upload.bat C:\Users\admin\Desktop\tosutile\IntoTheVoidSetup_1.0.1.1.exe SecondTest/Test false
rem 同名文件上传会覆盖
rem tos_upload.bat文件应与tosutil.exe放入同一文件夹

@echo off
tosutil config -i AKLTN2JlNTg5NGZmYTM1NDAxNzk5Mzc3YTVmNjI3ZmJhOGM -k Tm1GaU5EQTBOVFJpTURFNE5HWXhObUUzTlRsaE9UbGxNV0kzTVdGaU1XTQ== -e tos-cn-shanghai.volces.com -re cn-shanghai

set FILEPATH=%~1%
rem 设置文件路径，绝对路径

set UPLOADPATH=%~2%
rem 设置上传路径例如 路径tos://pc-launcher/SecondTest/PC_HaoYou/  输入SecondTest/PC_HaoYou

set ISDIR=%~3%
rem 设置是否是上传文件夹

set TOS=tos://pc-launcher/
set FULLPATH=%TOS%%UPLOADPATH%/
if exist %FILEPATH% (
    if %ISDIR%==true (
        tosutil cp %FILEPATH% %FULLPATH% -r) else (
            tosutil cp %FILEPATH% %FULLPATH%))


echo %FULLPATH%
echo %UPLOADPATH%

:end
pause